import 'package:flutter/material.dart';

import 'ToBePickedUp.dart';

class TaskPage extends StatefulWidget {
  const TaskPage({super.key});

  @override
  State<TaskPage> createState() => _TaskPageState();
}

class _TaskPageState extends State<TaskPage> {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: DefaultTabController(
        length: 3,
        child: Scaffold(
          appBar: AppBar(
            bottom: const TabBar(
              labelColor: Colors.red,
              indicatorColor: Colors.red,
              tabs: [
                Tab(
                  text: '待提货',
                ),
                Tab(
                  text: '在途',
                ),
                Tab(
                  text: '已完成',
                ),
              ],
            ),
            title: const Text('神领物流'),
            centerTitle: true,
          ),
          body: const TabBarView(
            //禁止滑动
            physics: NeverScrollableScrollPhysics(),
            children: [
              //待提货页面
              Tobepickedup(),
              Text('暂无在途数据'),
              Text('暂无已完成数据')
            ],
          ),
        ),
      ),
    );
  }
}
